package com.huatai.datacenter.utils;

import java.util.function.Supplier;

/**
 * @author gusiyi
 * @version 1.0
 * @className DataModelUtil
 * @description 描述：
 * @date 2023/5/29 14:55
 */
public class DataModelUtil {

	private DataModelUtil(){}

	/**
	 * 通过传入的菜单名与该模块实体名称，返回删除失败的具体详细信息
	 * @param deleteFailedMenuName
	 * @param deleteFailedDataName
	 * @param hasUsedMenuName
	 * @param supplier
	 * @return
	 */
	public static String getDeleteFailedMsg(String deleteFailedMenuName, String deleteFailedDataName, String hasUsedMenuName, Supplier<String> supplier){
		return deleteFailedMenuName + "->\"" + deleteFailedDataName + "\"删除失败,原因:" + hasUsedMenuName + "->" + supplier.get() +  "使用中;";
	}
}
